//
//  Address.swift
//  Monujo
//
//  Created by user on 2024/1/3.
//
//

import Foundation
import SwiftData


@Model 
public class Address {
    var nickname: String
    var address: String
    var importTime: Date
    var scanTime: Date
    var wallet: Wallet?
    
    
    @Relationship(deleteRule: .cascade, inverse: \Network.address)
    var networkList: [Network] = []
    
    
    init(nickname: String, address: String, importTime: Date, scanTime: Date, wallet: Wallet) {
        self.nickname = nickname
        self.address = address
        self.importTime = importTime
        self.scanTime = scanTime
        self.wallet = wallet
    }
    
}
